package com.aaa.controller;

import com.aaa.entity.PhoneInfo;
import com.aaa.service.PhoneService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;

@RestController
/**
 * @author ZP
 * @date 2020/7/21 16:43
 * @Description:
 */
public class PhoneController {
    @Resource
    private PhoneService phoneService;

    @RequestMapping("/selectPhone")
    public List<Map> FindAllPhone(){
        return phoneService.FindAllPhone();
    }
    @RequestMapping("/AddPhone")
    public int AddPhone(PhoneInfo phoneInfo){
        return phoneService.AddPhone(phoneInfo);
    }
}
